<template>
  <div v-for="(item, index) in filterlist" :key="item.name" :index="index">
    <div
      v-show="isCollapse"
      style="
        color: #fff;
        font-size: 1.6rem;
        height: 5rem;
        background-color: red;
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 0rem 1.5rem;
        width: 17rem;
      "
    >
      <p>{{ store.tabValue }}</p>
      <div class="right">
        <el-icon><Search /></el-icon>
        <el-icon style="margin-left: 1rem" @click="isCollapse = !isCollapse"
          ><Expand
        /></el-icon>
      </div>
    </div>
    <div
      v-if="!isCollapse"
      style="
        color: #fff;
        font-size: 1.6rem;
        height: 100vh;
        background-color: red;
        width: 2.5rem;
        padding-left: 1rem;
      "
    >
      <el-icon @click="isCollapse = !isCollapse"><Expand /></el-icon>
      <p>打开导航栏</p>
    </div>
    <!-- 问题 -->
    <el-menu
      v-else-if="isCollapse"
      default-active="1"
      class="el-menu-vertical-demo"
      style="height: 100vh; overflow-y:scroll" 
    >
      <el-sub-menu
        v-for="(item2, index2) in item.children"
        :key="index2"
        :index="item.name"
         @click="clickitem2(item2)"
      >
        <template #title >
          <el-icon><location /></el-icon>
          <span>{{ item2.name }}</span>
        </template>
        <el-menu-item-group>
          <el-menu-item
            v-for="(item3, index3) in item2.children"
            :key="index3"
            :index="item3.name"
            @click="clickitem3(item3)"
            >{{ item3.name }}</el-menu-item
          >
        </el-menu-item-group>
      </el-sub-menu>
    </el-menu>
  </div>
</template>

<script lang="ts" setup>
import { ref, computed ,onMounted} from "vue";

import {
  Document,
  Menu as IconMenu,
  Location,
  Setting,
} from "@element-plus/icons-vue";
import {useRouter} from "vue-router"
import {useCounterStore} from "@/stores/counter"
const router = useRouter()
const store = useCounterStore();


const isCollapse = ref(true);

//添加面包屑
const clickitem3 = async(item:any)=>{
  store.addCrumbs(item)
  router.push(item.path)
}
const clickitem2 = async(item:any)=>{
  if(!item.children){
    store.addCrumbs(item)
    router.push(item.path)
  }
  
}

//表数据
const menuList = ref([
  {
    name: "个人办公",
    path: "/",
    icon: "../assets/LeftMenu/个人办公.png",
    cate: "个人办公",
    children: [
      {
        name: "个人中心",
        path: "/document",
        icon: "../assets/LeftMenu/个人中心.png",
        children: [
          {
            name: "个人设置",
            path: "/personal_she",
            icon: "../assets/LeftMenu/个人设置.png",
          },
          {
            name: "提醒信息",
            path: "/personal_ti",
            icon: "../assets/LeftMenu/提醒信息.png",
          },
          {
            name: "个人资料",
            path: "/personal_ge",
            icon: "../assets/LeftMenu/个人资料.png",
          },
          {
            name: "我的薪资",
            path: "/personal_salary",
            icon: "../assets/LeftMenu/我的薪资.png",
          },
          {
            name: "内部通讯录",
            path: "/personal_contacts",
            icon: "../assets/LeftMenu/内部通讯录.png",
          },
          {
            name: "我上传过的文件",
            path: "/personal_file",
            icon: "../assets/LeftMenu/我上传过的文件.png",
          },
          {
            name: "我的培训考试",
            path: "/personal_examination",
            icon: "../assets/LeftMenu/我的培训考试.png",
          },
          {
            name: "我的会话记录",
            path: "/personal_session",
            icon: "../assets/LeftMenu/我的会话记录.png",
          },
        ],
      },
      {
        name: "邮件",
        path: "/email",
        icon: "../assets/LeftMenu/邮件.png",
      },
      {
        name: "日程",
        path: "/schedule",
        icon: "../assets/LeftMenu/日程.png",
      },
      {
        name: "单据查看",
        path: "/document",
        icon: "../assets/LeftMenu/单据查看.png",
      },
      {
        name: "订阅报表",
        path: "/address",
        icon: "../assets/LeftMenu/订阅报表.png",
      },
      {
        name: "会议",
        path: "/document",
        icon: "../assets/LeftMenu/会议.png",
      },
      {
        name: "我的考勤",
        path: "/document",
        icon: "../assets/LeftMenu/我的考勤.png",
      },
      {
        name: "工作日报",
        path: "/document",
        icon: "../assets/LeftMenu/工作日报.png",
      },
    ],
  },

  {
    name: "流程",
    path: "/document",
    icon: "../assets/LeftMenu/我的流程.png",
    cate: "流程",
    children: [
      {
        name: "代办/处理",
        path: "/document",
        icon: "../assets/LeftMenu/代办处理.png",
      },
      {
        name: "流程申请",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
      },
      {
        name: "我的申请",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
      },
      {
        name: "我申请未通过",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
      },
      {
        name: "我的下属申请",
        path: "/document",
        icon: "../assets/LeftMenu/我的下属申请.png",
      },
      {
        name: "经我处理",
        path: "/document",
        icon: "../assets/LeftMenu/我的下属申请.png",
      },
      {
        name: "授权单据查看",
        path: "/document",
        icon: "../assets/LeftMenu/我的下属申请.png",
      },
    ],
  },
  {
    name: "资源",
    path: "/document",
    icon: "../assets/LeftMenu/我的流程.png",
    cate: "资源",
    children: [
      {
        name: "文档中心",
        path: "/document",
        icon: "../assets/LeftMenu/代办处理.png",
      },
      {
        name: "共享的文档",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
      },
      {
        name: "知识信息管理",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
      },
      {
        name: "知识题库管理",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
      },
      {
        name: "知识信息查看",
        path: "/document",
        icon: "../assets/LeftMenu/我的下属申请.png",
      },
      {
        name: "知识题库学习",
        path: "/document",
        icon: "../assets/LeftMenu/我的下属申请.png",
      },
    ],
  },
  {
    name: "任务",
    path: "/document",
    icon: "../assets/LeftMenu/我的流程.png",
    cate: "任务",
    children: [
      {
        name: "项目管理",
        path: "/document",
        icon: "../assets/LeftMenu/代办处理.png",
        children: [
          {
            name: "我执行的项目",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "我未完成的项目",
            path: "/document",
            icon: "../assets/LeftMenu/我未完成的项目.png",
          },
          {
            name: "我负责的项目",
            path: "/document",
            icon: "../assets/LeftMenu/我未完成的项目.png",
          },
          {
            name: "我创建的项目",
            path: "/document",
            icon: "../assets/LeftMenu/我未完成的项目.png",
          },
          {
            name: "所有项目一览",
            path: "/document",
            icon: "../assets/LeftMenu/我未完成的项目.png",
          },
        ],
      },
      {
        name: "我的任务",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
      },
      {
        name: "我未完成任务",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
      },
      {
        name: "我下属任务",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
      },
      {
        name: "我创建任务",
        path: "/document",
        icon: "../assets/LeftMenu/我的下属申请.png",
      },
      {
        name: "任务督导",
        path: "/document",
        icon: "../assets/LeftMenu/我的下属申请.png",
      },
      {
        name: "、所有任务一览",
        path: "/document",
        icon: "../assets/LeftMenu/我的下属申请.png",
      },
    ],
  },
  {
    name: "公文",
    path: "/document",
    icon: "../assets/LeftMenu/我的流程.png",
    cate: "公文",
    children: [
      {
        name: "公文查阅",
        path: "/document",
        icon: "../assets/LeftMenu/代办处理.png",
      },
      {
        name: "发文单",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "所有发文单",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "收文单",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "所有收文单",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
    ],
  },
  {
    name: "客户",
    path: "/document",
    icon: "../assets/LeftMenu/我的流程.png",
    cate: "客户",
    children: [
      {
        name: "客户主页",
        path: "/document",
        icon: "../assets/LeftMenu/代办处理.png",
      },
      {
        name: "客户",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "我的客户",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "共享给我的",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "我下属客户",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "客户分配",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "销售机会",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "我的销售机会",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "我下属销售机会",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "合同",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "我的合同",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "我下属的合同",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "收款单",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "我的收款单",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "我下属的收款单",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "付款单",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "我的付款单",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "我下属的付款单",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "客户统计",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "我的客户统计",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "我下属客户统计",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "金额统计",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "我的财务统计",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "我下属财务统计",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "我年度统计",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "客户查看",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "客户一览表",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "所有销售机会",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "所有客户合同",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "所有收款单",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "所有付款单",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "所有财务统计",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
    ],
  }, {
    name: "人事考勤",
    icon: "../assets/LeftMenu/我的流程.png",
    cate: "人事考勤",
    children: [
      {
        name: "人事档案",
        icon: "../assets/LeftMenu/代办处理.png",
        children: [
          {
            name: "人员档案",
            path: "/archives",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "员工合同",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "人员分析",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "人事管理",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "转正申请",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "离职申请",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "人事调动",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "调薪申请",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "工作日报",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "所有日报",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "日报统计",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "日报统计分析",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "薪资管理",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "薪资核算",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "薪资发放",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "考勤设置",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "人员考勤设置",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "考勤时间规则",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "考勤时间分配",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "考勤时间排班",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "休息时间规则",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "休息时间分配",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "定位打卡位置",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "定位打卡位置分配",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "考勤信息",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "打卡记录",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "定位记录",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "外出记录",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "打卡异常",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "考勤信息",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "加班单核算",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "考勤分析",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "考勤统计简表",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "考勤统计详表",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },

      {
        name: "考试培训",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "考试培训列表",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "考试培训人员",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
    ],
  },
  {
    name: "行政",
    path: "/document",
    icon: "../assets/LeftMenu/我的流程.png",
    cate: "行政",
    children: [
      {
        name: "物品基础管理",
        path: "/document",
        icon: "../assets/LeftMenu/代办处理.png",
        children: [
          {
            name: "仓库管理",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "供应商管理",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "物品列表",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "物品管理",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "出入库操作",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "出入库详情",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "物品采购",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "物品领用",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "物品盘点",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "固定资产",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
      },
      {
        name: "车辆管理",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "车辆列表",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "车辆信息登记",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "车辆预定查询",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "车辆预定情况",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "车辆维修",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "车辆保养",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "财务管理",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "费用报销",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "费用报销报表",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "出差报销",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "借款单",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "借款单统计",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "还款单",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "付款申请",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "开票申请",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "图书管理",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "图书列表",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "图书借阅",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },

      {
        name: "印章管理",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "印章列表",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "印章申请查阅",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
    ],
  },
  {
    name: "流程模块",
    path: "/document",
    icon: "../assets/LeftMenu/我的流程.png",
    cate: "流程模块",
    children: [
      {
        name: "数据选项",
        path: "/document",
        icon: "../assets/LeftMenu/代办处理.png",
      },
      {
        name: "流程模块列表",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
      },
      {
        name: "审核人员分组",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
      },
      {
        name: "流程审核步骤",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
      },
      {
        name: "表单元素管理",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
      },
      {
        name: "流程模块权限",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
      },

      {
        name: "流程单据查看",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
      },
      {
        name: "单据操作菜单",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
      },
      {
        name: "流程模块条件",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
      },
      {
        name: "单据通知设置",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
      },
      {
        name: "流程模块统计",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
      },
      {
        name: "单据异常监控",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
      },
    ],
  },
  {
    name: "系统",
    path: "/document",
    icon: "../assets/LeftMenu/我的流程.png",
    cate: "系统",
    children: [
      {
        name: "基础管理",
        path: "/document",
        icon: "../assets/LeftMenu/代办处理.png",
        children: [
          {
            name: "公司单位",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "组织结构",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "用户管理",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "组管理",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "菜单管理",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "首页项管理",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "文档分区管理",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "邮件管理",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "邮件收发设置",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "用户邮箱设置",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "即时通信管理",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "服务器设置",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "会话管理",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "应用管理",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "会话记录",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "订阅管理",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "订阅管理",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "订阅报表",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "权限管理",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "人员->菜单",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "菜单->人员",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "组->菜单",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "菜单->组",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "人员权限查看",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
      {
        name: "系统工具",
        path: "/document",
        icon: "../assets/LeftMenu/流程申请.png",
        children: [
          {
            name: "系统设置",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "系统信息",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "数据库表",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "初始化备份",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "计划任务",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "上传文件管理",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "日志查看",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
          {
            name: "城市管理",
            path: "/document",
            icon: "../assets/LeftMenu/我执行的项目.png",
          },
        ],
      },
    ],
  },
]);
//筛选之后的数据
const filterlist = computed(() => {
  let storeVal = store.tabValue;
  return menuList.value.filter((item) => item.cate == storeVal);
});
</script>
<style lang="scss" scoped>
.el-menu-vertical-demo:not(.el-menu--collapse) {
  width: 20rem;
}

.ones {
  background-color: #b598b5;
  color: #fff;
  img {
    width: 1.4rem;
    height: 1.4rem;
  }
  .OneSpan {
    display: flex;
    align-items: center;
    img {
      width: 1.4rem;
      height: 1.4rem;
    }
  }
}
</style>
